package org.wlc.demov1;

/**
 * @author 王立朝
 * @date 2022/5/25
 * @description:
 */
public class SsoInterceptor implements HandlerIntercepter{
    /**
     * 前置拦截器
     *
     * @param request
     * @param response
     * @param handler
     * @return
     */
    @Override
    public boolean preHandle(String request, String response, Object handler) {

        // 模拟获取cookie
        String ticket = request.substring(1, 8);
        // 模拟检验
        return ticket.equals("success");
    }
}
